<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8" />
        <meta name="viewport" content="width=device-width, initial-scale=1.0" />
        <meta http-equiv="X-UA-Compatible" content="ie=edge" />
        <title>Document</title>
    </head>
    <body>
        <div>123</div>

        <img
            src="https://img11.360buyimg.com/babel/s1180x940_jfs/t1/68960/4/7146/65482/5d52547fEdf2a90c1/7a2be2ff2b663521.jpg.webp"
            alt=""
        />

        <script src="./jquery/jquery-3.6.0.js"></script>

        <script>
            // ·将div元素设置为方形粉色的盒子，点击事件只能执行一次
            $("div").css({
                width:200,
                height:200,
                backgroundColor:"pink"
            }).one("click",function () {
                console.log($(this));
            })

            // ·使用3种方式监听页面资源加载完毕事件
            window.onload = function () {
                console.log("页面资源加载完毕");
            }

            $(window).ready(function () {
                console.log("页面资源加载完毕");
            })

            $(function () {
                console.log("页面资源加载完毕");
            })

        </script>
    </body>
</html>
